package router

import (
	"github.com/gin-gonic/gin"
	"shop_api/user_web/middlewares"

	"shop_api/user_web/api"
)

func InitUserRouter(r *gin.RouterGroup) {
	userRouter := r.Group("user")
	{
		userRouter.GET("list", middlewares.JWTAuth(), middlewares.IsAdminAuth(), api.GetUserList)
		userRouter.POST("pwd_login", api.PasswordLogin)
		userRouter.POST("register", api.Register)
	}
}
